﻿@model Angel.Web.Models.DeleteUserModel
@{
    ViewBag.Title = "DeleteUser";
}

<h2>DeleteUser</h2>
<p>
    Please enter Id of user you want to delete.
</p>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

@Html.ValidationSummary(true, "Delete not success! Please try again.")

@using (Html.BeginForm())
{
    <div>
        <fieldset>
            <legend>Delete Form</legend>

            <div class="editor-label">
                @Html.LabelFor(m => m.userId)
            </div>
            <div class="editor-field">
                @Html.TextBoxFor(m => m.userId)
                @Html.ValidationMessageFor(m => m.userId)
            </div>
            <p>
                <input type="submit" value="Delete" onclick="return myFunction()"/>
            </p>
        </fieldset>
    </div>
}
            
<script type="text/javascript">
    function myFunction()
    {
        var r = confirm("Do you want to delete this user?");
        return r;
    }
</script>